package thread.thread4;

import java.io.File;
import java.io.FileNotFoundException;
import java.io.PrintStream;

public class TestThread {

	public static void main(String[] args) throws FileNotFoundException {
		System.setOut(new PrintStream(new File("bank.txt")));
		Account ac = new Account("张洋", 10000);
		MoneyTaker t1 = new MoneyTaker("张洋父母", ac);
		MoneyTaker t2 = new MoneyTaker("张洋老婆", ac);
		MoneyTaker t3 = new MoneyTaker("张洋小三", ac);
		MoneyTaker t4 = new MoneyTaker("张洋小四", ac);
		MoneySaver m = new MoneySaver("张洋", ac);
		m.start();
		t1.start();
		t2.start();
		t3.start();
		t4.start();
	}

}
